public class Test {

    //按位异或：1.相同为0，不同为1
    //无符号右移，符号位补0，没有无符号左移


        public static void main(String[] args) {
            double x=2.0;
            int y=4;
            x/=++y;
            System.out.println(x);//0.4
        }

    public static void main10(String[] args) {
        System.out.println((true == true)?(true == true) ? false : true : true);//阿里面试

    }

    public static void main9(String[] args) {
        int a = -1;
        System.out.println(a >>> 1);
    }

    public static void main8(String[] args) {
        int a = 1;
        int b = 2;

        System.out.println(a);
    }

    public static void main7(String[] args) {
        System.out.println(1 < 5);
        System.out.println(1 <= 5);
        System.out.println(1 > 5);
        System.out.println(1 >= 5);
        System.out.println(1 != 5);
        System.out.println(1 == 5);
        int a = 10;


    }

    public static void main6(String[] args) {
        int a = 10;
        int b = a++;

        System.out.println(a);
        System.out.println(b);
    }


    public static void main5(String[] args) {
        int a = 10;
        a += 1;//a = a + 1;
        System.out.println(a);

        short sh = 12;
        //sh = sh + 2;报错
        sh += 2;//14
        System.out.println(sh);
    }
    public static void main4(String[] args) {
        System.out.println(10%3);//1
        System.out.println(10%-3);//1
        System.out.println(-10%3);//-1
        System.out.println(-10%-3);//-1
    }

    //java数据类型有两种：1.基本数据类型2.引用数据类型String Byte
    public static void main3(String[] args) {
        int a = 1234;
        String ret = String.valueOf(a);
        System.out.println(ret);

        float f = 12.5f;
        String ret1 = String.valueOf(f);
        System.out.println(ret1);
    }

    public static void main2(String[] args) {
        int a = 10;
        int b = 20;
        System.out.println("a = "+a);
        System.out.println("b = "+b);
        System.out.println("a+b="+(a+b));
    }

    public static void main1(String[] args) {
        String str = "hello";
        String str1 = "mbj";
        //在字符串中，如果两个字符串进行相加，那么意思就是拼接
        System.out.println(str+str1);

        System.out.println(str);
        int a = 10;
        System.out.println(a);
    }
}
